package com.ler.yrmall.product.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.ler.yrmall.basic.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.math.BigDecimal;

/**
 * sku
 * @author leron
 */
@Data
@TableName("pms_sku")
@EqualsAndHashCode(callSuper = true)
public class SkuEntity extends BaseEntity<SkuEntity> {

    /**
     * spuId
     */
    @JsonSerialize(using = ToStringSerializer.class)
    private Long spuId;

    /**
     * sku名称
     */
    private String name;

    /**
     * sku详情
     */
    private String skuDesc;

    /**
     * 分类
     */
    private Long categoryId;

    /**
     * 品牌id
     */
    private Long brandId;

    /**
     * 封面
     */
    private String cover;

    /**
     * 价格
     */
    private BigDecimal price;

    /**
     * 销量
     */
    private Long saleCount;

    /**
     * 状态
     */
    private Integer status;

}
